#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include "qtreewidget.h"
#include <QFtp>
#include <QMainWindow>

namespace Ui {
class MainWindow;
}

class MainWindow : public QMainWindow
{
    Q_OBJECT

public:
    explicit MainWindow(QWidget *parent = nullptr);
    ~MainWindow();

private:
    Ui::MainWindow *ui;
    QFtp *ftp;

    void ftpCommandFinished(int commandId, bool error);
    void addToList(const QUrlInfo &urlInfo);
//    void processItem(QTreeWidgetItem *item, int column);
//    void cdToParent();
    void updateDataTransferProgress(qint64 readBytes, qint64 totalBytes);




    void processItem(QTreeWidgetItem *item, int column);

private:
    QHash<QString, bool> isDirectory;
    QString currentPath;
};

#endif // MAINWINDOW_H
